using PluginForDNSRecord;

namespace DNSRecordAliyunCommon.Test
{
    [TestClass]
    public class UnitTest_AliyunDnsRecordEditor
    {
        private readonly IDNSRecordEditor dNSRecordEditor;
        public UnitTest_AliyunDnsRecordEditor()
        {
            dNSRecordEditor = new AliyunDnsRecordEditor();
            dNSRecordEditor.Config = new Dictionary<string, string>()
            {
                { "AccessKeyID","123456"},
                { "AccessKeySecret","666666"},
            };
        }

        [TestMethod]
        public void TestMethod_AliyunDnsRecordEditor()
        {
            var res = dNSRecordEditor.EditDnsRecord("domain.com", "_acme-challenge","TXT", "Microsoft.VisualStudio.TestTools.UnitTesting").GetAwaiter().GetResult();
            Assert.AreEqual(res.Result,true);
        }
    }
}